package cn.tnar.model.service.impl;

import cn.tnar.model.entity.TAcctCustLoginInfo;
import cn.tnar.model.mapper.TAcctCustLoginInfoMapper;
import cn.tnar.model.service.ITAcctCustLoginInfoService;
import cn.tnar.request.ConditionRequest;
import cn.tnar.request.LoginRequest;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

/**
 * @Author: 陈亮
 * @Date: 2018/10/12 16:15
 */
@Repository
@Mapper
@Service
public class TAcctCustLoginInfoServiceImpl extends ServiceImpl<TAcctCustLoginInfoMapper, TAcctCustLoginInfo> implements ITAcctCustLoginInfoService {

    @Override
    public Page<TAcctCustLoginInfo> selectListPage(int current, int size) {
        Page<TAcctCustLoginInfo> page = new Page<TAcctCustLoginInfo>(current, size);
        EntityWrapper<TAcctCustLoginInfo> eWrapper = new EntityWrapper<>(null);
        Page<TAcctCustLoginInfo> tAcctCustLoginInfoPage = selectPage(page, eWrapper);
        return tAcctCustLoginInfoPage;
    }

    @Override
    public TAcctCustLoginInfo login(LoginRequest request, Wrapper<TAcctCustLoginInfo> wrapper) {
        TAcctCustLoginInfo tAcctCustLoginInfo = selectOne(wrapper);
        return tAcctCustLoginInfo;
    }

}
